Greeting Properties |
||
|
||
|
|
|
Greeting Methods |
||
|
||
|
||
|
Greeting objects are collections of Phrase objects. The For.... Each statement can be used to iterate through all the phrases in a greeting.
Dim phr as Phrase
For Each phr in greet
Debug.Print phr.filename
Next
For more examples, see the description of the example CustPhrs.
The name of this greeting
The play format of this greeting - one of the vbvFileFormatConstants:
vbvULAW_8K = 0
vbvALAW_8K = 0(Use of A-law or μ-law is controlled by the UseAlaw INI setting)
vbvOKI_8K = 1
vbvULAW_6K = 2
vbvALAW_6K = 2
vbvOKI_6K = 3
vbvLIN8_8K = 4
vbvLIN8_11K = 5
Not all formats are supported by all voice cards. All cards support vbvULAW_8K or vbvALAW_8K.
(Index as Integer)
Each phrase object in a greeting can be accessed through this property. The phrase objects can then be manipulated using the Phrase methods and properties below.
(Boolean)
Signifies whether playing the greeting terminates when a DTMF digit is detected.
Copy(Greeting as Object)
This method makes a copy of the greeting object provided by copying all phrases in it.
Count() As Integer
Returns the number of phrases in this greeting.
Note: The Insert methods all create a new, empty Phrase object, and then use one of the Phrase Create methods to create a valid phrase. See Phrase Methods for more details on phrase creation.
InsertFile(Position as Integer, Filename as String)
Inserts a VOX or WAV file into the greeting by creating a new phrase, executing the CreateWavePhrase method on it, and inserting it into the greeting at the specified position. Other phrases are moved down in the list to make room for the new phrase.
InsertIndexPhrase(Position as Integer, FileName as String, Index as String)
Creates a new phrase object, executes the CreateIndexPhrase method on it, and inserts it into the greeting at the specified position. Other phrases are moved down in the list to make room for the new phrase.
InsertNamedPhrase(Position as Integer, FileName as String, PhraseName as String)
Creates a new phrase object, executes the CreateNamedPhrase method on it, and inserts it into the greeting at the specified position. Other phrases are moved down in the list to make room for the new phrase.
InsertSysPhrase (Index as Integer, Type as Integer, Data1 as String, Data2 as String)
Creates a new phrase, executes the CreateSysPhrase method on it, and inserts it into the greeting at the specified position. Other phrases are moved down in the list to make room for the new phrase.
RemoveAt(Index as Integer)
Removes the phrase at the given position and deletes the object.
RemoveAll()
Removes all the phrases from the greeting and deletes them.
Phrase Properties |
||
|
||
|
||
|
|
|
Phrase Methods |
||
|
||
|
|
These properties can be used to query the contents of a phrase or to modify the phrase. You should create new phrases using the methods described below.
(String)
The filename of the WAV or VAP file for a VAP phrase. For system phrases, this property contains the PhraseData1 field.
The play format (reserved for future use).
(String)
Phrase data, having different meanings depending on the phrase type.
(vbvSysPhraseConstants)
The type of system phrase. See vbvSysPhraseConstants.
(vbvSysPhraseConstants)
The type of system phrase. See vbvSysPhraseConstants.
The type of phrase - wavefile, system phrase, or VAP file.
Copy(Phrase as Object)
This method creates a phrase that is a copy of an existing phrase.
CreateIndexPhrase(Filename as String, Index as Integer)
This method creates a phrase object that refers to a phrase in a VAP file. The phrase is referenced by position. Index 0 is the first phrase.
CreateNamedPhrase(Filename as String, PhraseName as String)
This method creates a phrase that refers to a phrase in a VAP file. The phrase is referenced by the name of the script. The phrase name is case-sensitive.
CreateSysPhrase(PhraseType as Integer, Data1 as String, Data2 as String)
This method creates a system phrase. PhraseType is one of the vbvSysPhraseConstants. The Data1 and Data2 parameters are dependent on the phrase type. See System Phrase Types for types of system phrase and required data for each type.
CreateWavePhrase(Filename as String)
Creates a phrase that refers to a WAV file. The file is played in its entirety.